home *** CD-ROM | disk | FTP | other *** search
/ Celestin Apprentice 2 / Apprentice-Release2.iso / Source Code / C / Frameworks / PennyWise™ Framework / PennyView / Source / InitApplication.c < prev    next >
Encoding:
Text File  |  1994-08-11  |  1.7 KB  |  62 lines  |  [TEXT/KAHL]

  1. //••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••
  2. //                                                                                //
  3. //                                                                                //
  4. //                    Copyright PennyWise Software, 1994.                            //
  5. //                                                                                //
  6. //            Part of the PennyWise Software Application Framework                //
  7. //                                                                                //
  8. //                                                                                //
  9. //            InitApplication.c        Written by Peter Kaplan                        //
  10. //                                                                                //
  11. //                                                                                //
  12. //••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••
  13. // Local Includes
  14. #include "CoreAppleEvents.h"
  15. #include "DefaultHandlers.h"
  16. #include "HandleMenus.h"
  17. #include "InitApplication.h"
  18. //••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••
  19. // Added for PennyView
  20. #include <Movies.h>
  21. #include "MovieWindow.h"
  22. #include "PictWindow.h"
  23. #include "TextWindow.h"
  24. //••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••
  25. void InitApplication()
  26. {
  27. Rect    boundsRect;
  28.  
  29.     // Set up the menus
  30.     InitOurMenus();
  31.     
  32.     // Set up the AppleEvents
  33.     InitOurAppleEvents();
  34.     
  35.     EnterMovies();                    //••••••••••• Added for PennyView 
  36.     
  37.     // Set up the default handlers
  38.     InitDefaultHandlers();
  39.  
  40.     // Here is where you will add the handlers
  41.     InitMovieWindowHandlers();        //••••••••••• Added for PennyView
  42.     InitPictWindowHandlers();        //••••••••••• Added for PennyView
  43.     InitTextWindowHandlers();        //••••••••••• Added for PennyView
  44. }
  45. //••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••
  46. void InitOurMenus()
  47. {
  48.     ClearMenuBar();
  49.  
  50.     gMenuApple = GetMenu(kMENU_ID_APPLE);                          
  51.     InsertMenu (gMenuApple,0);
  52.     AddResMenu(gMenuApple,'DRVR');
  53.     
  54.     gMenuFile = GetMenu(kMENU_ID_FILE);
  55.     InsertMenu (gMenuFile,0);
  56.  
  57.     gMenuEdit = GetMenu(kMENU_ID_EDIT);
  58.     InsertMenu (gMenuEdit,0);
  59.  
  60.     DrawMenuBar();
  61. }
  62.